import {createRouter, createWebHistory, RouteRecordRaw} from "vue-router";

const routes: Array<RouteRecordRaw> = [
    {
        path: '/HomeIndex',
        name: 'HomeIndex',
        component: () => import('../home/HomeIndex.vue')
    },
    {
        path: '/',
        redirect: '/HomeIndex'
    },

    /**  svg icon  */
    {
        path: '/SVGComponentIndex',
        name: 'SVGComponentIndex',
        component: () => import('@/views/common/SVGIcon/SVGIconIndex.vue')
    },
    /**  轮播动画 */
    {
        path: '/RotateAnimationIndex',
        name: 'RotateAnimationIndex',
        component: () => import('@/views/common/rotateAnimation/RotateAnimationIndex.vue')
    },

    /**  element plus */
    {
        path: '/ElTableIndex',
        name: 'ElTableIndex',
        component: () => import('../views/elementPlus/el-table/ElTableIndex.vue')
    },
    {
        path: '/MultilevelHeadTable',
        name: 'MultilevelHeadTable',
        component: () => import('../views/elementPlus/el-table/MultilevelHeadTable.vue')
    },
    {
        path: '/FormExample',
        name: 'FormExample',
        component: () => import('../views/elementPlus/form/FormExample.vue')
    },

    /**  vue3 */
    {
        path: '/GetStartedQuicklyDoc',
        name: 'GetStartedQuicklyDoc',
        component: () => import('../views/vue3/getStartedQuickly/GetStartedQuicklyDoc.vue')
    },
    /**  前端截图 */
    {
        path: '/ScreenshotIndex',
        name: 'ScreenshotIndex',
        component: () => import('../views/vue3/screenshot/ScreenshotIndex.vue')
    },
    /**  大文件上传 */
    {
        path: '/FileUploadIndex',
        name: 'FileUploadIndex',
        component: () => import('../views/vue3/fileUpload/FileUploadIndex.vue')
    },
    /**  前端生成二维码 */
    {
        path: '/QRcodeIndex',
        name: 'QRcodeIndex',
        component: () => import('../views/vue3/QRcode/QRcodeIndex.vue')
    },
    /**  组件传递 */
    {
        path: '/ComponentTransmissionIndex',
        name: 'ComponentTransmissionIndex',
        component: () => import('../views/vue3/ComponentTransmission/ComponentTransmissionIndex.vue')
    },
    /**  前端水印 */
    {
        path: '/WatermarkIndex',
        name: 'WatermarkIndex',
        component: () => import('../views/vue3/watermark/WatermarkIndex.vue')
    },
    /**  useCommandComponent 弹框 */
    {
        path: '/useCommandComponent',
        name: 'useCommandComponent',
        component: () => import('../views/vue3/useCommandComponent/Index.vue')
    },

    /**  echart */
    {
        path: '/echartsIndex',
        name: 'echartsIndex',
        component: () => import('../views/echarts/apache/EchartsIndex.vue')
    },
    {
        path: '/VueEchartsIndex',
        name: 'VueEchartsIndex',
        component: () => import('../views/echarts/vue-echart/VueEchartsIndex.vue')
    },

]

const router = createRouter({
    history: createWebHistory('/vue3Demo'),
    routes
})

export default router